<?php
class Util {
    static function jsAlert($_msg = false, $_url = false) {
        $strJs = '';
        if ($_msg != false) {
            $strJs = "alert('$_msg');";
        }
        if ($_url != false) {
            $strJs .= "window.location.href = '$_url';";
        }
        die("<script type='text/javascript'>$strJs</script>");
    }
}
